#include "cmddlg.h"
#include "ui_cmddlg.h"

#include <QPainter>

CmdDlg::CmdDlg(QWidget *parent)
    : QWidget(parent)
    , ui(new Ui::CmdDlg)
{
    ui->setupUi(this);
    this->label = ui->label_2;
    setWindowFlag(Qt::FramelessWindowHint);
}

CmdDlg::~CmdDlg()
{
    delete ui;
}

void CmdDlg::paintEvent(QPaintEvent *event)
{
    QPainter painter(this);
    QPen pen(c);
    pen.setWidth(1); // 设置边框宽度
    painter.setPen(pen);
    painter.drawRoundedRect(rect().adjusted(0, 0, -1, -1),4,4);
}
